package com.mingqi.enetconnected.primary.mytask.activity;

import android.view.View;
import android.widget.EditText;
import android.widget.TextView;
import android.widget.Toast;

import com.mingqi.enetconnected.R;
import com.mingqi.enetconnected.base.BaseActivity;
import com.mingqi.enetconnected.primary.mytask.event.PutTableEvent;
import com.mingqi.enetconnected.view.MultipleTextSwitch;

import org.greenrobot.eventbus.EventBus;

import butterknife.BindView;

public class AddGasToolActivity extends BaseActivity {

    @BindView(R.id.tv_save)
    TextView mTvSave;
    @BindView(R.id.tv_device_name)
    TextView mTvDeviceName;
    @BindView(R.id.tv_device_type)
    TextView mTvDeviceType;
    @BindView(R.id.mts_device_state)
    MultipleTextSwitch mMtsDeviceState;
    @BindView(R.id.et_install_place)
    EditText mEtInstallPlace;
    @BindView(R.id.tv_install_date)
    TextView mTvInstallDate;
    @BindView(R.id.tv_start_date)
    TextView mTvStartDate;
    @BindView(R.id.tv_finish_date)
    TextView mTvFinishDate;

    @Override
    protected int getLayoutID() {
        return R.layout.activity_add_gas_tool;
    }

    @Override
    protected void initView() {

        setTitleName(R.string.add_gas_tool);
    }

    @Override
    protected void initClick() {

        mTvSave.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {

                Toast.makeText(AddGasToolActivity.this, "保存成功", Toast.LENGTH_SHORT).show();
                EventBus.getDefault().post(new PutTableEvent(false));
                finish();
            }
        });
    }
}
